Package-level declarations

Types

Link copied to clipboard
data class BookInformation(val id: String, val title: String, val subtitle: String = "", val coverUri: Uri = Uri.EMPTY, val author: String, val description: String, val tags: List<String> = emptyList(), val publishingHouse: String, val wordCount: WordCount, val lastUpdated: LocalDateTime, val isComplete: Boolean)

书本详情接口

Link copied to clipboard

书本相关的Api

Link copied to clipboard
data class BookVolumes(val bookId: String, val volumes: List<Volume>)

书本卷目录

Link copied to clipboard
data class ChapterContent(val id: String, val title: String, val content: JsonObject, val prevChapter: String? = null, val nextChapter: String? = null)

章节内容接口

Link copied to clipboard
data class ChapterInformation(val id: String, val title: String)

章节基础信息

Link copied to clipboard

本地书本数据源接口 提供对本地存储的书本数据的增删改查操作

Link copied to clipboard
data class UserReadingData(val id: String, val lastReadTime: LocalDateTime? = null, val totalReadTime: Int = 0, val readingProgress: Float = 0.0f, val lastReadChapterId: String? = null, val lastReadChapterTitle: String? = null, val currentChapterReadingProgressMap: Map<String, Float> = mapOf(), val maxChapterReadingProgressMap: Map<String, Float> = mapOf())

用户书本阅读数据接口

Link copied to clipboard
data class Volume(val volumeId: String, val volumeTitle: String, val chapters: List<ChapterInformation>)

书本卷信息

Link copied to clipboard
@Serializable
data class WordCount(val count: Int, val unit: String?, @StringRes val unitResId: Int?)

用于存储书本字数的对象 可以灵活更变其单位 如果unit与unitResId都是null 那么会默认使用 字 作为单位